<?php

namespace App\Controllers;

use Sys\Helper\PHPExcelHelper;

/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2017/11/14
 * Time: 11:47
 */
class IndexController extends Controller
{
    public function index()
    {

        $data = db('users')->select('*')->setAll()->query();
        dump($data);
        dump(db()->lastSQL());
        return $this->view('layout.html', ['name' => 'sgme']);
    }

    public function test()
    {
//        return range(0, 100);
    }

    public function xls()
    {
        $data = PHPExcelHelper::importAtImage(PUBLIC_PATH . 'test.xlsx', PUBLIC_PATH);
        dump($data);
    }
}